
package com.xyzwps.server.paimon.ext

import kotlin.time.Clock
import kotlin.time.DurationUnit
import kotlin.time.Instant
import kotlin.time.toDuration

fun instantNow(): Instant = Clock.System.now()

fun Instant.plusDays(days: Int): Instant = this + days.toDuration(DurationUnit.DAYS)

fun Instant.minusMinutes(minutes: Int): Instant = this - minutes.toDuration(DurationUnit.MINUTES)

fun Instant.minusDays(days: Int): Instant = this - days.toDuration(DurationUnit.DAYS)

